//
//  MusicBigDataModel.m
//  YHYRealx
//
//  Created by yanghuiyan on 16/4/26.
//  Copyright © 2016年 yanghuiyan. All rights reserved.
//

#import "MusicBigDataModel.h"
#import "MusicDetailDataModel.h"
@implementation MusicBigDataModel

- (void)dealloc {
    
    [_name release];
    [_style release];
    [_data release];
    [super dealloc];
}

- (instancetype)initWithDataSource:(NSDictionary *)dataSource
{
    self = [super init];
    if (self) {
        
        [self setValuesForKeysWithDictionary:dataSource];
        
        NSMutableArray *array = [NSMutableArray array];
        for (NSDictionary *dic in self.data) {
            MusicDetailDataModel *model = [[MusicDetailDataModel alloc] initWithDataSource:dic];
            [array addObject:model];
            
        }
        self.data = [NSArray arrayWithArray:array];
    }
    return self;
}
@end
